<?php

use yii\helpers\Html;
use yii\helpers\Url;
use yii\widgets\ActiveForm;

?>
<div class="modal modal-sm">
    <a href="javascript:void(0);" class="modal-overlay"></a>
    <div class="modal-container">
        <div class="modal-header d-flex">
            <div class="modal-title h4 col-mr-auto">注册</div>
            <a href="javascript:void(0);" class="btn btn-clear"></a>
        </div>
        <div class="modal-body">
            <div class="content">
                <div class="form-group">
                    <div class="text-right">
                        <span class="text-muted">已有账号？<a href="javascript:void(0);" class="ajax-modal" data-href="<?= Url::to(['auth/login']); ?>">马上登录</a> </span>
                    </div>
                </div>
                <?php $form = ActiveForm::begin(); ?>

                <?= $form->field($model, 'username')->textInput(['placeholder' => $model->getAttributeLabel('username'), 'class' => 'form-input', 'autocomplete' => 'off'])->label(FALSE); ?>

                <?= $form->field($model, 'nickname')->textInput(['placeholder' => $model->getAttributeLabel('nickname'), 'class' => 'form-input', 'autocomplete' => 'off'])->label(FALSE); ?>

                <?= $form->field($model, 'email')->textInput(['placeholder' => $model->getAttributeLabel('email'), 'class' => 'form-input', 'autocomplete' => 'off'])->label(FALSE); ?>

                <?= $form->field($model, 'password')->passwordInput(['placeholder' => $model->getAttributeLabel('password'), 'class' => 'form-input', 'autocomplete' => 'off'])->label(FALSE); ?>

                <div class="form-group">
                    <?= Html::submitButton(Yii::t('app', 'Sign up'), ['class' => 'btn btn-block btn-danger btn-lg btn-auth']) ?>
                </div>

                <?php ActiveForm::end(); ?>
            </div>
        </div>
    </div>
</div>


